package com.liefox.serviceedu.client;

import com.liefox.commonutils.R;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @Author zjh
 * @Date 2021/7/17 下午 9:55
 **/
@FeignClient(name="service-vod",fallback = VodFileDegradeFeignClient.class)
@Component
public interface VodClient {
    @ApiOperation(value = "删除视频")
    @DeleteMapping("/eduvod/video/{videoId}")
    public R removeVideo(@ApiParam(name = "videoId", value = "云端视频id", required = true)
                         @PathVariable("videoId") String videoId);
                        //记得@PathVariable要指定参数

    @ApiOperation(value = "删除多个视频")
    @DeleteMapping("/eduvod/video/delMore")
    public R delMore(@RequestParam("videoIdList") List<String> videoIdList);
}
